package com.qf.wangqing.sportsnews.utils;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.PopupWindow;
import android.widget.TextView;

import com.qf.wangqing.sportsnews.R;

/**
 * Created by Administrator on 2016/12/19.
 */

public class CompetitionPoWinShare extends PopupWindow {
    private View mainView;
    private TextView layoutShare, popwin_all,popwin_NBA,popwin_footabl,popwin_FIFA,popwin_basketball;

    public CompetitionPoWinShare(Context context, View.OnClickListener pareOnClickListener, int paramWidth, int paramHight) {
        super(context);
        mainView = LayoutInflater.from(context).inflate(R.layout.fragment_competition_popwin_share, null);

        layoutShare= (TextView) mainView.findViewById(R.id.layout_share);
        popwin_all= (TextView) mainView.findViewById(R.id.popwin_all);
        popwin_NBA= (TextView) mainView.findViewById(R.id.popwin_NBA);
        popwin_footabl= (TextView) mainView.findViewById(R.id.popwin_footabl);
        popwin_FIFA= (TextView) mainView.findViewById(R.id.popwin_FIFA);
        popwin_basketball= (TextView) mainView.findViewById(R.id.popwin_basketball);
        if(pareOnClickListener!=null){
            layoutShare.setOnClickListener(pareOnClickListener);
            popwin_all.setOnClickListener(pareOnClickListener);
            popwin_NBA.setOnClickListener(pareOnClickListener);
            popwin_footabl.setOnClickListener(pareOnClickListener);
            popwin_FIFA.setOnClickListener(pareOnClickListener);
            popwin_basketball.setOnClickListener(pareOnClickListener);
        }
        setContentView(mainView);
        setWidth(paramWidth);
        setHeight(paramHight);

    }
}
